package com.wn.mapper;

import com.wn.common.pojo.Traveller;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface TravellerMapper {
       int deleteByPrimaryKey(@Param("updateUserId")Integer updateUserId,@Param("travellerId") Integer travellerId);
       Traveller selectByPrimaryKey(int id);
       List<Traveller> selectByCondition(Traveller traveller);
       int update(Traveller traveller);
       int insert(Traveller traveller);
       int insertTravellerUser(@Param("travellerId") Integer travellerId,@Param("userId") Integer userId,@Param("createUserId") Integer createUserId);
       int deleteTravellerUserByTravellerId(int travellerId);

       //为每一个订单中的旅客信息添加旅客
       Integer insertTravellerByOrder(Traveller traveller);
       /*根据订单中的旅客信息为旅客表增加旅客*/
       Integer insertTempByTravellerIdAndOrderId(@Param("travellerId") Integer travellerId,
                                                 @Param("orderId") Integer id);
}
